package com.jackiechan.day14;

import java.util.Scanner;

public class HaHa {
    public static void main(String[] args) {
        show();
    }

    private static void show() {
        System.out.print("请输入电话号码:");
        String str = new Scanner(System.in).nextLine();
        StringBuilder sb1 = new StringBuilder(str);
        StringBuilder sb = null;
        System.out.println(sb);
        for (int i=0,j=0;i<str.length();i++){
            sb =sb1.deleteCharAt(sb1.indexOf(" "));
        }
        System.out.println(sb);
        String ts = sb.substring(str.length()-11,str.length());
        System.out.println(ts);
        String cs = sb.substring(0,str.length()-10);
        String leftts = ts.substring(0,3);
        String rightts = ts.substring(ts.length()-4);
//        String c = ;
        System.out.println("+**-"+leftts+"-****-"+rightts);
    }

}
